<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link rel="stylesheet" type="text/css" href="./CSS/DVD_control.css" />
<script type="text/javascript" src="js/jquery-1.6.2.min.js"></script>
<script type="text/javascript">
var  channelnum="";
$(function() { 
	
	 $("#second  input[type=button]").click(function(){
	 	  
	 	   channelnum+=$(this).val();
		
			
	 	   timeoutProcess=setTimeout(function(){
		       
			      if(""!=channelnum) {  
	               alert(channelnum);
			
				     channelnum="";
					 	   /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "channel="+channelnum,		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
				   }
				 
			  
				    
					
				
	                	
                    },800);
	 	  
	 	  
	 	
	});
	
	 $(".directionbutton").click(function(){
	 	  
	 	  alert($(this).attr("name"));
	 	     /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+$(this).attr("name"),		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
	 	  
	 	
	});
});
	
function powerHandler(){
	
	if($("input[name=power]").attr("ispress")=="false"){
		$("input[name=power]").attr("ispress","true");
			$("input[name=power]").val("关电源");
				 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"poweron",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
		
	}else{
		$("input[name=power]").attr("ispress","false");
			$("input[name=power]").val("电源");
				 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"poweroff",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
	}

}	

function playHandler(){
	 alert("播放");
	   /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"play",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function pauseHandler(){
	 alert("暂停");
	   /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"pause",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function stopHandler(){
	 alert("停止");
	 	  /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"stop",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function fastforwardHandler(){
	alert("快进");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"forward",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function fastbackwardHandler(){
	alert("快退");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"backward",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function preHandler(){
	alert("上一首");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"prev",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function nextHandler(){
	alert("下一首");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"next",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}



function audiotrackHandler(){
	alert("声道");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"track",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function subtitleHandler(){
	alert("字幕");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"subtitle",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function exitHandler(){
	alert("出仓");
	 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"eject",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}

function menuHandler(){
	alert("菜单");
		 /* $.ajax({		  
                       type: get,		  
                       url: http://xx.xxx.xx.xx/cgi-bin/DVD_control.cgi,		 
                       data: "operation="+"menu",		  
                        success: function(msg){			 alert( "数据发送成功" + msg );		 
                       }		
              }); */
}


</script>	
</head>

<body>
<p id="text_area0">DVD机控制</p>
<div id="hardisk_VCR"> 
<dl id="first">
<dd>
<input name="power" type="button" value="电源" ispress="false" onclick="powerHandler()" />
<input name="play" type="button" value="播放" ispress="false" onclick="playHandler()"/>
<input name="pause" type="button" value="暂停" ispress="false" onclick="pauseHandler()"/>
<input name="stop" type="button" value="停止" ispress="false" onclick="stopHandler()"/>
</dd>
<dd>
<input name="fastforward" type="button" value="快进" ispress="false" onclick="fastforwardHandler()"/>
<input name="fastbackward" type="button" value="快退" ispress="false" onclick="fastbackwardHandler()"/>
<input name="pre" type="button" value="上一首" ispress="false" onclick="preHandler()"/>
<input name="next" type="button" value="下一首" ispress="false" onclick="nextHandler()"/>
</dd>
<dd>
<input name="audio_track" type="button" value="声道" ispress="false" onclick="audiotrackHandler()"/>
<input name="subtitle" type="button" value="字幕" ispress="false" onclick="subtitleHandler()"/>
<input name="exit" type="button" value="出仓" ispress="false" onclick="exitHandler()"/>
<input name="menu" type="button" value="菜单" ispress="false" onclick="menuHandler()"/>
</dd>
</dl>
<dl id="second">
<dd>
<input class="normal" name="one" type="button" value="1" />
<input class="normal" name="two" type="button" value="2" />
<input class="normal" name="three" type="button" value="3" />
</dd>
<dd>
<input class="normal" name="four" type="button" value="4" />
<input class="normal" name="five " type="button" value="5" />
<input class="normal" name="six" type="button" value="6" />
</dd>
<dd>
<input class="normal" name="seven" type="button" value="7" />
<input class="normal" name="eight" type="button" value="8" />
<input class="normal" name="nine" type="button" value="9" />
</dd>
<dd>
<input id="zero" name="zero" type="button" value="0" />
<input id="sharp" name="sharp" type="button" value="#" />
</dd>
</dl>
<dl id="third">
<dd id="up">
<input  class ="directionbutton" name="up" type="button" value="上" />
</dd>
<dd id="middle">
<input class ="directionbutton" name="left" type="button" value="左" />
<input class ="directionbutton" id="confirm" name="confirm" type="button" value="确定" />
<input class ="directionbutton" name="right" type="button" value="右" />
</dd>
<dd id="down">
<input class ="directionbutton" name="down" type="button" value="下" />
</dd>
</dl>
</div>
</body>
</html>
